<extend name="public/base"/>
<block name="style">
</block>
<block name="body">
<div class="layui-card qn-header">
	<div class="layui-breadcrumb">
		<a href="">首页</a>
		<a href="{:U('index')}">后台导航管理</a>
		<a href=""><cite>{:isset($info['id'])?'编辑':'新增'}后台菜单</cite></a>
	</div>
</div>
<div class="layui-fluid">
	<div class="layui-card">
		<div class="layui-card-body">
		
		<form action="{:U()}" id="form" class="layui-form" method="post">
		<div class="form-body">
			<div class="layui-form-item">
				<label class="layui-form-label">标题</label>
				<div class="layui-input-inline">
					<input class="layui-input" placeholder="" type="text" name="title" value="{$info.title|default=''}">
				</div>
				<div class="layui-form-mid layui-word-aux">用于后台显示的配置标题</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">排序</label>
				<div class="layui-input-inline">
					<input class="layui-input" placeholder="" type="text" name="sort" value="{$info.sort|default=0}">
				</div>
				<div class="layui-form-mid layui-word-aux">用于分组显示的顺序</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">链接地址</label>
				<div class="layui-input-inline">
					<input class="layui-input" placeholder="" type="text" name="url" value="{$info.url|default=''}">
				</div>
				<div class="layui-form-mid layui-word-aux">U函数解析的URL或者外链</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">上级菜单</label>
				<div class="layui-input-inline">
					<select class="form-control select2me" name="pid">
						<volist name="Menus" id="menu">
							<option value="{$menu.id}" <if condition="$info['pid'] eq $menu['id']">selected</if> >{$menu.title_show}</option>
						</volist>
					</select>
				</div>
				<div class="layui-form-mid layui-word-aux"></div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">所属模块</label>
				<div class="layui-input-inline">
					<select class="form-control select2me" name="module">
						<option value="">空</option>
						<volist name="Modules" id="vo">
							<option value="{$vo.name}" <if condition="$info['module'] eq $vo['name']">selected</if>>{$vo.alias}</option>
						</volist>
					</select>
				</div>
				<div class="layui-form-mid layui-word-aux"></div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">图标CLASS</label>
				<div class="layui-input-inline">
					<input class="layui-input" placeholder="" type="text" name="icon" value="{$info.icon|default=''}">
				</div>
				<div class="layui-form-mid layui-word-aux">顶级菜单请填写图标class,二级三级菜单留空</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">二级菜单分组名</label>
				<div class="layui-input-inline">
					<input class="layui-input" placeholder="" type="text" name="group" value="{$info.group|default=''}">
				</div>
				<div class="layui-form-mid layui-word-aux">用于分组二级菜单</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">是否隐藏</label>
				<div class="layui-input-inline">
					<input type="radio" name="hide" value="1" <if condition="$info.hide eq 1">checked</if> title="是"/>
					<input type="radio" name="hide" value="0" <if condition="$info.hide eq 0">checked</if> title="否"/>
				</div>
				<div class="layui-form-mid layui-word-aux"></div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">仅开发者模式可见</label>
				<div class="layui-input-inline">
					<input type="radio" name="is_dev" value="1" <if condition="$info.is_dev eq 1">checked</if> title="是"/>
					<input type="radio" name="is_dev" value="0" <if condition="$info.is_dev eq 0">checked</if> title="否"/>
				</div>
				<div class="layui-form-mid layui-word-aux"></div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">简单介绍</label>
				<div class="layui-input-inline">
					<input class="layui-input" placeholder="" type="text" name="tip" value="{$info.tip|default=''}">
				</div>
				<div class="layui-form-mid layui-word-aux">菜单详细说明</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label"></label>
				<div class="layui-input-inline">
				<div class="layui-footer">
					<input type="hidden" name="id" value="{$info.id|default=''}">
					<button class="layui-btn layui-btn-sm ajax-post" id="submit" type="submit" target-form="layui-form">确定</button>
					<button onclick="javascript:history.back(-1);return false;" class="layui-btn layui-btn-sm layui-btn-primary">返回</button>
				</div>
				</div>
				<div class="layui-form-mid layui-word-aux"></div>
			</div>
        </div>
        </form>
      </div>
    </div>
</div>
</block>

<block name="jquery_script">
Think.setValue("pid", {$info.pid|default = 0});
Think.setValue("hide", {$info.hide|default = 0});
Think.setValue("is_dev", {$info.is_dev|default = 0});
</block>
<block name="script">
</block>